
import 'package:flutter/cupertino.dart';
import 'package:myapp/repository/api.dart';

import '../../repository/datas/search_data.dart';

class SearchViewModel with ChangeNotifier{

  List<SearchListData>? searchList;

  Future search(String? keyword) async{
    searchList = await Api.instance.searchList(pageCount: "0",keyword:keyword);
    notifyListeners();
  }

  void clear(){
    searchList?.clear();
    notifyListeners();
  }
}